package com.tianji.remark.service;

import com.tianji.api.dto.remark.LikedTimesDTO;
import com.tianji.remark.domain.dto.LikeRecordFormDTO;
import com.tianji.remark.domain.po.LikedRecord;
import com.baomidou.mybatisplus.extension.service.IService;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;
import java.util.Map;

/**
 * <p>
 * 点赞记录表 服务类
 * </p>
 *
 * @author author
 * @since 2025-03-26
 */
public interface ILikedRecordService extends IService<LikedRecord> {

    /**
     * 根据ids获得点赞数量结果
     * @param ids
     * @return
     */
    List<LikedTimesDTO> getByIds(List<Long> ids);

    /**
     * 添加点赞数或移除点赞数
     * @param likeRecordFormDTO
     */
    void addLike(LikeRecordFormDTO likeRecordFormDTO);

    /**
     * 返回当前用户对所有业务的点赞情况
     * @return
     */
    Map<Long, Boolean> isLiked(List<Long> ids);

    void readLikeTimesAndSendMessage();
}
